package heritage.single.table;

import java.util.Date;

import javax.persistence.DiscriminatorValue;
import javax.persistence.Entity;

@Entity
@DiscriminatorValue(value = "ce")
public class CompteEpargne extends Compte {

	private static final long serialVersionUID = -3152210786892288022L;
	
	private double tauxInteret;
	
	public CompteEpargne() {
	}
	
	public CompteEpargne(String codeCompte, Date dateCreation, double solde,
			double tauxInteret) {
		super(codeCompte, dateCreation, solde);
		this.tauxInteret = tauxInteret;
	}

	public double getTauxInteret() {
		return tauxInteret;
	}

	public void setTauxInteret(double tauxInteret) {
		this.tauxInteret = tauxInteret;
	}

	@Override
	public String toString() {
		return "CompteEpargne [tauxInteret=" + tauxInteret + ", codeCompte="
				+ codeCompte + ", dateCreation=" + dateCreation + ", solde="
				+ solde + "]";
	}
}
